• Resolved gcwp

    (@gcwp)


    Hello

    ‘have just created a twentyseventeen child theme but the menu icon shows a cross when clicked using an iphone!

    why?!

    Cheers

    Geoff

Viewing 15 replies - 16 through 30 (of 39 total)
  • Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Oh I keep forgetting to look at the other pages!
    Okay, try this:

    
    
    @media screen and (max-width: 767px) {
        .navigation-top,
        #masthead .wrap {
            position: static;
        }
    
        .site-branding,
        .custom-header-media {
            z-index: 0;
        }
    
        .main-navigation {
            left: 10%;
            position: absolute;
            top: 0;
            width: 80%;
            z-index: 1;
        }
    
        .main-navigation ~ a {
            display: inline-block;
            margin-top: 10px;
        }
    
        html .colors-custom.navigation-top .menu-toggle,
        html .navigation-top .menu-toggle {
            background: white;
            color: red;
            float: right;
            z-index: 1;
        }
    
        html .colors-custom.twentyseventeen-front-page .navigation-top .menu-toggle,
        html .twentyseventeen-front-page .navigation-top .menu-toggle {
            float: none;
            margin-top: 20.5em;
        }
    
        .menu-menu-1-container {
            clear: both;
        }
    
        html .colors-custom .menu-toggle:focus,
        html .menu-toggle:focus {
            background: white;
            outline-color: black;
        }
    
    }
    
    Thread Starter gcwp

    (@gcwp)

    Andrew

    that’s fine for the non-front pages but could it be at the top of the front page too?

    Cheers

    Geoff

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Oh that makes it easier, try:

    
    /* For screens smaller than 767px */
    @media screen and (max-width: 767px) {
        /* Remove the relative positioning on the containing elements so that it does not interfere with the new menu button position */
        .navigation-top,
        #masthead .wrap {
            position: static;
        }
    
        /* Ensure the other header elements do not overlap the menu button */
        .site-branding,
        .custom-header-media {
            z-index: 0;
        }
    
        /* Positioning the container for the main menu so the menu button and menu itself are moved together */
        .main-navigation {
            left: 10%;
            position: absolute;
            top: 0;
            width: 80%;
            z-index: 1;
        }
    
        /* Styling the share links to have a small gap above them */
        .main-navigation ~ a {
            display: inline-block;
            margin-top: 10px;
        }
    
        /* Making the menu button more visible and positioning it to the right */
        html .colors-custom.navigation-top .menu-toggle,
        html .navigation-top .menu-toggle {
            background: white;
            color: red;
            float: right;
            margin-top: 1em;
            z-index: 1;
        }
    
        /* Ensuring the menu itself sits clear of the menu button */
        .menu-menu-1-container {
            clear: both;
        }
    
        /* Making the focus state of the menu button visible */
        html .colors-custom .menu-toggle:focus,
        html .menu-toggle:focus {
            background: white;
            outline-color: black;
        }
    }
    
    
    • This reply was modified 7 years, 11 months ago by Andrew Nevins. Reason: Added comments to CSS
    Thread Starter gcwp

    (@gcwp)

    Andrew

    the last version is fine. Many thanks!

    Which line is it that I can play around with the move the Menu to the right a little more?

    Cheers

    Geoff

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Here:

    
    
        .main-navigation {
            left: 10%;
            position: absolute;
            top: 0;
            width: 80%;
            z-index: 1;
        }
    

    Specifically either the ‘left’ or ‘width’ values

    Thread Starter gcwp

    (@gcwp)

    just another thought…

    I would have thought that the twentyseventeen code itself would not have placed the Menu at the bottom of the front page so that the list of page titles is off the screen on the iphone?

    Geoff

    Thread Starter gcwp

    (@gcwp)

    OK – thanks again!

    Cheers

    Geoff

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    It shouldn’t place the menu beneath the ‘fold’ point, I didn’t realise this was the underlying issue.

    Thread Starter gcwp

    (@gcwp)

    sorry, what is the “fold” point?

    Geoff

    Thread Starter gcwp

    (@gcwp)

    perhaps I caused the problem with

    .panel-content {
    display: none;
    }

    ?

    Geoff

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    I don’t think hiding the panel content would effect this. What I mean by the ‘fold’ is the bottom of the screen without scrolling. Typically search engines refer to the term “above the fold”. I just meant that Twenty Seventeen should not be showing the menu beneath the bottom of your screen, it should show it at the bottom but it should still be visible without you scrolling.

    Thread Starter gcwp

    (@gcwp)

    OK so is this a fault with the theme?

    I’m not clear whether you work with the twentyseventeen code people?

    Geoff

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    The TwentySeventeen people don’t get paid and I’m not part of their team (and I don’t get paid), so there’s not a relationship where they/we “work” for WordPress.

    What I’m trying to understand is if the issue you’re describing is a bug or whether it’s a feature of the theme.

    If the menu is showing beneath the ‘fold’, as in the bottom of the screen before you scroll down, then that’s a bug with the theme and we can help you fix that in another thread.

    If the menu is showing at the bottom of the screen but above the ‘fold’ then that’s the theme design.

    Thread Starter gcwp

    (@gcwp)

    Andrew

    have removed all the css in the child theme and this is the screen view.

    bug or design?screen pic

    Geoff

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    That’s the theme design.

Viewing 15 replies - 16 through 30 (of 39 total)
  • The topic ‘menu icon iphone not working?!’ is closed to new replies.