Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #225898

    Hi guys!

    I used to be able to display the regular menu on ipad using this code, posted in some support posts here:

    @media only screen and (max-width: 989px) and (min-width: 768px) {
    .responsive .main_menu ul:first-child > li > a {
    padding: 0 6px;
    font-size: 10px;
    }
    
    .main_menu {
    margin-right: -20px;
    }
    
    .main_menu ul:first-child > li > a {
    padding: 0 11px;
    }
    
    .logo img {
    width: 200px;
    }
    }

    But now it’s not working anymore. When loading the page, the menu appears for a second, and then disapear behind what looks like a white layer.

    Any idea how to resolve this?

    Thanks!

    #225901

    Hey wizbiz!

    What is the url for your site?

    Cheers!
    Devin

    #225905
    This reply has been marked as private.
    #226194

    Hi!

    Please add following code to Quick CSS in Enfold theme options under Styling tab

    @media only screen and (max-width: 989px) and (min-width: 768px) {
    .responsive .mobile_menu_tablet .main_menu {
    display: block;
    }}

    Best regards,
    Yigit

    #226241

    Hi,

    Thanks, but this displays the responsive menu when seen on tablet. I want to display the regular menu on tablet.

    To sum things up, I want to display:

    – the regular menu over 989px,
    – the responsive menu under 767px,
    – the regular menu with adapted logo width, font size and padding for everything between 768px and 988px.

    Basically what I used to do before, using the code I gave you earlier.

    Cheers.

    #226605

    Hey!

    Edit js > avia.js, find this code on 307:

    if(first_level_items > 7 + header.find('#menu-item-search').length && !bottom_menu)
        	{
        		switchWidth = 989;
        		header.addClass('mobile_menu_tablet');
        	}

    Replace it with:

    if(first_level_items > 7 + header.find('#menu-item-search').length && !bottom_menu)
        	{
        		switchWidth = 767;
        		header.addClass('mobile_menu_tablet');
        	}

    This will force the theme to only show the responsive menu on screen sizes lower than 768px.

    Best regards,
    Ismael

    #226694

    Thanks, with the modified java and the custom css posted by yigit this worked. Only problem left is that the size of the text won’t reduce like it used to.

    Here is the custom css I’m using:

    @media only screen and (max-width: 989px) and (min-width: 768px) {
    .responsive .mobile_menu_tablet .main_menu {
    display: block;
    padding: 0 6px;
    font-size: 10px;
    }
    
    .main_menu {
    margin-right: -30px;
    }
    
    .main_menu ul:first-child > li > a {
    padding: 0 11px;
    }
    }

    The “font-size” doesn’t apply. Any idea what I’m doing wrong?

    Cheers!

    #226830

    Hey!

    Please try to add !important beside the css value:

    @media only screen and (max-width: 989px) and (min-width: 768px) {
    .responsive .mobile_menu_tablet .main_menu {
    display: block;
    padding: 0 6px !important;
    font-size: 10px !important;
    }
    
    .main_menu {
    margin-right: -30px;
    }
    
    .main_menu ul:first-child > li > a {
    padding: 0 7px !important;
    }
    }

    Best regards,
    Ismael

    #226952

    Thanks, but unfortunately this didn’t change anything.

    Cheers.

    #227607

    Hi!

    Please try adding following code to Quick CSS

    @media only screen and (max-width: 989px) and (min-width: 768px) { 
    .main_menu ul:first-child > li > a { font-size: 10px; }}

    Cheers!
    Yigit

    #227622

    Thanks for your answer.

    If I use this CSS, the previous issue comes back, meaning that when loading the page, the menu appears for a second, and then disapear behind what looks like a white layer.

    But for the second it does appear, I can see the font parameter applied properly.

    Cheers.

    #227623

    Ok, I managed to make it work.

    The white layer issue is gone.
    On desktop, the header shows normally with a resolution over 989px.
    On tablet (between 768px and 989px), the regular menu shows, with smaller font, smaller logo, and reduced padding. Tested on ipad 2 and ipad mini.
    On smartphone (under 768px), it switches to the responsive menu.

    Here is the code:

    @media only screen and (max-width: 989px) and (min-width: 768px) {
    .responsive .mobile_menu_tablet .main_menu {
    display: block;
    }
    
    .main_menu {
    margin-right: -30px;
    }
    
    .main_menu ul:first-child > li > a {
    font-size: 10px;
    }
    
    .logo img {
    width: 250px !important;
    }
    }

    I ended up removing the padding attributes, as it didn’t seem to make any difference.

    Thank a lot for your help!

    • This reply was modified 10 years, 10 months ago by wizbiz.
Viewing 12 posts - 1 through 12 (of 12 total)
  • The topic ‘Enfold: Menu problem on ipad’ is closed to new replies.