Archived topic
Centering Navigation with same formatting when Sticky
22 replies · Started by jregist on October 21, 2020
Sorry for the long delay -- I had a truly terrible css conflict that was driving me crazy. It is resolved now, I believe.
I still have a slight format change when the menu goes from normal to sticky on scroll. Can you take a look and suggest how that might be resolved. Thanks!
Looks like you've added the sticky navigation logo back in again?
It shouldn't be needed as it's the same as the static logo.
Then remove all the CSS you've added for the site logo like this one:
.site-logo {
width: 28%;
}
I do want the logo to stay in that position when the user scrolls down the page -- I just don't want it to change its appearance or there to be any noticeable change in its formatting. Sorry for the confusion.
I'm having a difficult time trying to figure out why the logo disappears on the scroll.
Can you do the following:
- Activate the parent theme.
- Add this CSS in the Additional CSS field in the customizer:
https://docs.generatepress.com/article/centering-logo-navigation/
Plus this CSS:
.main-navigation .main-nav {
flex-grow: 1;
}
- Disable all plugins except GP Premium.
Done. I had to modify a different page since I de-activated the page builder I'm using (Beaver Builder)
Oops. Let me set up the header in the parent.
Thanks - that seemed to reveal the issue(s). When I followed your instructions, the logo stays fixed. When I pasted in the styles that I had added in the child theme, the logo disappeared on scroll again. I'll work on this some more in the morning and follow up if continue to having issues. Really appreciate the help!
No problem :)