- This topic has 21 replies, 3 voices, and was last updated 4 years, 5 months ago by
Leo.
-
AuthorPosts
-
December 6, 2018 at 2:25 pm #750090
Kritish
Hi,
I have tried a few CSS from other topics and am unable to fix the title being misaligned on mobile view. I just needed the logo/title to be on top with the menu underneath, I tried with both mobile header enabled and disabled.
December 6, 2018 at 5:38 pm #750195Leo
StaffCustomer SupportHi there,
Are you currently removing the site header using the Layout Elements?
If so can you try using this CSS instead so the normal header shows on mobile
@media (min-width: 769px) { .site-header { display: none; } }
Adding CSS: https://docs.generatepress.com/article/adding-css/
Let me know when this is done π
December 6, 2018 at 6:19 pm #750210Kritish
Hi Leo,
Yes I am using elements to remove the header and have moved the title into the navigation following instructions from the documentation page.
The code you gave did nothing.
December 6, 2018 at 8:17 pm #750244Leo
StaffCustomer SupportCan you first disable that element which is removing the header?
Then the CSS should hide the normal header on desktop only and shows on mobile.
The normal header is closer to what you have in mind.
Let me know if this makes sense π
December 6, 2018 at 11:58 pm #750317Kritish
Hi Leo,
I have done as you have said and disabled the element(which looks like it was doing nothing anyways) and added your CSS but the title still doesn’t look good in mobile view.
December 7, 2018 at 6:18 am #750541David
StaffCustomer SupportHi there,
try this:
@media (max-width: 400px) { .main-navigation .site-branding a { font-size: 16px; } }
December 9, 2018 at 12:16 pm #752257Kritish
Hi David,
Thanks for your help, I am bad with CSS and using what you gave I made some adjustments to make the mobile view slightly better.
December 9, 2018 at 4:59 pm #752373David
StaffCustomer SupportGlad to be of help π
December 9, 2018 at 7:52 pm #752437Kritish
Hi David,
I know I already marked this as resolved, but I wasn’t sure if I should open another topic since it will be continuing on from what I did here. My boss wasn’t too happy as to how the title came out in mobile view on the iPhone X and has asked if the title can be changed on just mobile view.
I tried the following CSS and wasn’t sure why it changed the layout completely and made it non-responsive(I think?).
@media (max-width: 400px) { .main-navigation .site-branding a { visibility:hidden; } } @media (max-width: 400px) { .main-navigation .site-branding a:after { visibility:visible; content:"OLMC"; } }
December 10, 2018 at 3:25 am #752678David
StaffCustomer SupportHi there,
have you considered creating a mobile logo? You can then use the mobile header which has its own logo option.
December 10, 2018 at 12:16 pm #753171Kritish
Hi David,
I had tried mobile header, but doing so didn’t display the title/crest as it is viewed on desktop view, which is why I was trying to change the text of the title when viewing in mobile view to the shortened form of just OLMC.
So my end goal was ‘Crest OLMC hamburger menu’ all in 1 line.
December 10, 2018 at 3:49 pm #753290Leo
StaffCustomer SupportSo where would the toggle be?
On the right of the title text?
December 10, 2018 at 4:06 pm #753309Kritish
Hi Leo,
That is correct if you mean the menu toggle.
December 10, 2018 at 5:11 pm #753340Leo
StaffCustomer SupportWith the logo I assume? Might be quite tight for space.
Can you disable the mobile header again?
December 10, 2018 at 5:29 pm #753347Kritish
Yes that is correct, that is why I wanted to change the full title to just “OLMC” using the CSS from my previous post.
-
AuthorPosts
- You must be logged in to reply to this topic.