Site logo

Archived topic

Is It Possible to do a Side Push Menu?

13 replies · Started by Samuel on July 21, 2020

Viewing posts 1–14 of 14

I'm working on a site where it would be nice to use a side menu. I've tried to configure it in GP and when the menu is activated the whole page has an overlay and the menu comes in on top. Is there a way to have a menu that pushes the page over. This website has an example of what I'd like to do: https://www.desiringgod.org The Hamburger menu on the far right pushes the page over on desktop and on mobile completely pushes the side over. Is there a setting or some custom css that I could use to get a similar effect on GP?

Thank you--I will try this and see if I can get what I'm after.

You're welcome

I looked at the other thread and used the css, but I have two problems I can't quite figure out:

1. The overlay still covers the entire site. What's the best way to limit the overlay to just the menu width so it pushes the page over. Right now the page is pushing over but the overlay obscures it.

2. How can I also have the header part of the page slide over? Right now only the page content slides over.

I noticed you told the other person to use navigation as header but if I check that my header looks way off.

Can you share a link to your site?
You can edit your original topic and use the Site URL field to share a link privately

Try this CSS:

.site,
.site-header {
    -webkit-transition: -webkit-transform .2s cubic-bezier(.16, .68, .43, .99);
    -moz-transition: -moz-transform .2s cubic-bezier(.16, .68, .43, .99);
    -o-transition: -o-transform .2s cubic-bezier(.16, .68, .43, .99);
    transition: transform .2s cubic-bezier(.16, .68, .43, .99);
    -webkit-backface-visibility: hidden;
    -webkit-perspective: 1000;
}

.slide-opened .site,
.slide-opened .site-header {
    -webkit-transform: translate3d(-265px, 0, 0);
    -moz-transform: translate3d(-265px, 0, 0);
    -ms-transform: translate3d(-265px, 0, 0);
    -o-transform: translate3d(-265px, 0, 0);
    transform: translate3d(-265px, 0, 0);
}

.slideout-overlay {
    background-color: rgba(0, 0, 0, 0) !important;
}

.main-navigation:not(.slideout-navigation) .main-nav,
#mobile-header .menu-toggle {
    order: -1;
}

in Customizer > Layout > Header you can enable the Mobile Header option.

Thats not the normal behaviour of the Mobile Header - default is logo left and menu toggle right. Would need to see the site to see whats interfering with it. Any chance this can wait until you go move it to a staging site ?

Yes, I will close this out and you can check it out when we go to staging.

Let us know when we can see it :)

This archived topic is closed to new replies.