-
AuthorPosts
-
October 1, 2018 at 11:06 am #1016555
Hi,
I try to put my menu on 2 lines for 2 tabs. When I write ‘Ravalement<br>de façade”, there is a large vertical space between the first and the second line (“ravalement” and “de façade”), the label comes out of the menu.
What CSS code should I insert to correct this ,
Thank you very much for your help,October 1, 2018 at 11:31 am #1016558Multiline Menus See here: https://kriesi.at/documentation/enfold/menu/#multiline-menu
by the way – if you like to have the menu floats right:
set that rule to
justify-content: flex-end;
October 1, 2018 at 11:34 am #1016561Thank you for your answer but it is not what I am looking for, I want to put on 2 lines the content of one label,
October 1, 2018 at 11:58 am #1016575in this case i would it do the way you do ( with a br inbetween the lines) but give the menupoint a custom class.
Do you know how to?
On menu there is on top of the window in the right corner a flyout “Screen Options”
– there you have “Show advanced menu properties” – mark : CSS Classes.
So now you can give to each menupoint a custom class.
i gave to the concerning menu-point the class: twolinertry than the following values in your quick css:
.twoliner a { line-height: 25px !important; } .twoliner a { line-height: 25px !important; height: auto !important; transform: translateY(50%); position: relative; } .twoliner .avia-menu-fx { bottom: -3px !important; }
these have to be adjusted to your dimensions. If we can see a link it would be more easy to advice
you can see it here on the right side of my testpage menu: https://webers-testseite.de/if you like to have the text centered add the rule to the anchor element .twoliner a :
text-align: center;October 1, 2018 at 12:06 pm #1016580this will be the right way – but i tested it on shrinking header – there must be new rules than to add.
Just a moment …edit: what kind of header setting do you have?
The one with the shrinking header is a bit complex – because we had to edit: avia-snippet-sticky-header.jsOctober 2, 2018 at 6:35 pm #1017172Thank you Guenni007 for your help, I finally decided to shorten my labels, however the solution to this question still interests me for other websites.
October 2, 2018 at 7:24 pm #1017185with a non shrinking header it is easy – see above
shrinking header – see testpage – if this meets your expectations, then I can offer the solution here on occasion.December 5, 2018 at 7:34 pm #1041352Hello,
I want to achieve exactly the same as sitadi but without a shrinking header. So I added your code but the space between the first and second line is too wide. I want the second line to be directly below the first one. I also want the white line to stay at the same height as the others.
Is that possible? How should I do it?My code so far is
.twoliner a { line-height: 25px !important; text-align: center !important; } .twoliner a { line-height: 25px !important; height: auto !important; transform: translateY(-30%); position: relative; } .twoliner .avia-menu-fx { bottom: -3px !important; }
This is how it looks like: picture
Thank you in advance!
Best regardsDecember 6, 2018 at 5:46 am #1041492Hi ping-pong,
Thanks for the screenshot, could you post a link to where we can see the actual results as well please?
Best regards,
RikardDecember 19, 2018 at 5:55 pm #1047281The link to the actual result is in the private content field. It is in the horizontal main menu
December 19, 2018 at 7:52 pm #1047353Hi,
Please try adding this code to the Quick CSS section under Enfold > General Styling or to your child theme’s style.css file:
CSS Snippet:
#top .main_menu .menu > li#menu-item-5023 > a { line-height: 20px!important; top: 20px; }
Best regards,
YigitDecember 22, 2018 at 5:11 pm #1048562It works so far, thank you!
The only thing still not so nice is that the white line is higher than the other ones. Is there a possibility to fix this?
ScreenshotDecember 22, 2018 at 11:09 pm #1048712Hi,
There is no easy way to do this but as an alternate solution you can hide the border by using the below CSS
CSS Snippet:
/* CSS - */ .av_seperator_small_border .av-main-nav > li > a > .avia-menu-text { border: none !important; }
Unfortunately, it would require quite some time and customization of the theme to achieve this modification, so I am sorry to tell you that this is not covered by our support. However, if it’s really important for you to get this done, you can always hire a freelancer to do the job for you :)
Best regards,
VinayNovember 6, 2019 at 11:15 am #1154229Dear All,
I need some help, please. I’d like to split the main menu in two rows from a certain menu item. I tried almost all the codes I found in the forum but none of them seemed to work. One code made my mobile menu disappear, the others weren’t functioning either.
Will you please help?
Thanks in advance.
November 7, 2019 at 5:28 am #1154520Hi darnott75,
What exactly are you looking to achieve? Please try to explain a bit further or post a screenshot highlighting your intentions.
Best regards,
RikardNovember 7, 2019 at 8:27 am #1154559Hi Rikard,
thank you for the reply. I attach a screenshot. The red line indicates the menu item from I’d like to wrap the rest of the menu items wrap under the first line. Basically I’d like to wrap 4 menu points under the 6 first menus.
How is this possible?Thanks in advance.
November 10, 2019 at 8:46 pm #1155384Hi,
@darnott75 is this what you are trying for:
https://i.postimg.cc/25nqGrRs/2019-11-10-134400.png#top #header_main > .container .main_menu .av-main-nav > li > a { height: 60px !important; line-height: 60px !important; } #menu-item-489 { clear: left !important; }
Best regards,
MikeNovember 11, 2019 at 10:05 am #1155518Hi Mike,
thank you, yes, indeed. However, do you think the menu can get closer to the logo? ThereÍs a huge gap between the logo and menu.
Thank you in advance.
November 11, 2019 at 10:09 am #1155519Also, it looks not so good on tablet. How can i activate mobile burger menu on tablet?
Thank you very much for your help.
This is solved with this code:
@media only screen and (max-width: 1024px) {
nav.main_menu {
display: block !important;
}
#avia-menu .menu-item {
display: none;
}
.av-burger-menu-main.menu-item-avia-special {
display: block;
}
}- This reply was modified 5 years, 1 month ago by darnott75.
November 11, 2019 at 11:37 am #1155544Hi,
Glad to hear you solved the burger menu, to move the main menu closer to the logo, please try this css:#top #header_main .main_menu { right: 10% !important; }
feel free to adjust, then clear your browser cache, and check.
Best regards,
MikeNovember 12, 2019 at 4:36 pm #1156041Thank you very much for the great support :)
It works like charm:)November 12, 2019 at 9:34 pm #1156181Hi,
I’m glad this was resolved. If you need additional help, please let us know here in the forums.
Best regards,
Jordan ShannonNovember 21, 2019 at 9:56 am #1158762Dear All,
I need some help, please. I split the main menu in two rows using this code.
#top #header_main > .container .main_menu .av-main-nav > li > a {
height: 60px !important;
line-height: 60px !important;
}
#menu-item-489 {
clear: left !important;
}
and moving the main menu closer to the logo:
#top #header_main .main_menu {
right: 10% !important;
}
It worked. however, I added an EN menu after using Polylang.
It doesn’t seem to work on the English menu.Will you please help?
Thanks in advance.
November 21, 2019 at 1:48 pm #1158822Hi,
Sorry, the two links you posted redirect to the same page for me, so they look the same.
Perhaps screenshots would help. Please try https://postimg.cc/ to add screenshots.Best regards,
MikeNovember 22, 2019 at 3:14 am #1158974Hi Mike,
Thank you for your reply, II upload the screenshot and try to post a link again.
November 22, 2019 at 3:15 am #1158975And the link in private content
November 22, 2019 at 1:06 pm #1159119Hi,
Thank you, Please try this code in the General Styling > Quick CSS field or in the WordPress > Customize > Additional CSS field:nav.main_menu { width: 70% !important; }
Best regards,
MikeNovember 23, 2019 at 6:37 pm #1159490Hi Mike,
thank you again, this looks great now:)
November 23, 2019 at 9:08 pm #1159509Hi,
Glad we were able to help, we will close this now since this thread was started over a year ago and is quite long. Thank you for using Enfold. For any other questions or issues, feel free to start new threads in the Enfold forum and we will gladly try to help you :)For your information, you can take a look at Enfold documentation here
Best regards,
Mike -
AuthorPosts
- The topic ‘Menu in 2 lines’ is closed to new replies.