-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixed Navbar with Mobile Collapse broken in 0.97.8 #3844
Comments
The code I have comes directly from http://materializecss.com/navbar.html#mobile-collapse and http://materializecss.com/navbar.html#navbar-fixed For a Fixed Navbar, it says all that is needed is to "add an outer wrapping div with the class navbar-fixed" I'll test the code you provided, perhaps the instructions are not completely clear. |
Then That Means That The Developers Didn't Document It Properly |
http://materializecss.com/buttons.html Their FAB-To-Toolbar Documentation Isn't Clearly Documented Aswell |
The Solution: <header>
<div class="navbar-fixed">
<nav>
<div class="nav-wrapper"> <a href="#!" class="brand-logo">Logo</a>
<a href="#" data-activates="mobile-demo" class="button-collapse"><i class="material-icons">menu</i></a>
<ul class="right hide-on-med-and-down">
<li><a href="sass.html">Sass</a></li>
<li><a href="badges.html">Components</a></li>
<li><a href="collapsible.html">Javascript</a></li>
<li><a href="mobile.html">Mobile</a></li>
</ul>
</div>
</nav>
</div>
<!-- Move the sidenav outside of .navbar-fixed -->
<ul class="side-nav" id="mobile-demo">
<li><a href="sass.html">Sass</a></li>
<li><a href="badges.html">Components</a></li>
<li><a href="collapsible.html">Javascript</a></li>
<li><a href="mobile.html">Mobile</a></li>
</ul>
</header> |
I have the same error :( |
Bump, this is an issue. Yeah you can work around it like mentioned before, but its bad for seo as @tomscholz said already |
there’s something really wrong with the mobile nav in 97.8 so we’re shipping with 97.7 for now until this is fixed. see issue here Dogfalo/materialize#3844
materialize issue #3844 was causing the menu overlay to cover the mobile navmenu making it unclickable. Restructured the header markup to work around the issue. Dogfalo/materialize#3844
Still no fix for this? |
@tomscholz didn't seem to work for me at all, even when copied exactly on a new file. just turned off the overlay for now |
@dkrish can you post a codepen with your code? |
for now, this is my fix:
|
Here is a fix that I used: |
I'm not sure if this is the same issue but I've been trying to use introjs inside the What I found was if I removed both the |
Hm, I thought I'd written another comment on this but it looks like it never sent. When This is the main cause of this bug. The Some people have suggested modifying the z-index of either Unless we find a work around for children of a To those concerned about the |
Quite right — remove |
@bretonio Or... You could just move the left-nav to the outside of fixed-nav div like solution on answer number 6 by @tomscholz ... 🤔 |
Hi guys! This is the HTML fix no CSS or anything else, like @kurotsukikaitou says:
This issue can be closed. |
Please refrain from posting comments and pictures that do not pertain to the discussion. |
Documentation has been updated in 7d94806 to make the HTML placement more clear |
I'm using this after all .css called.. #sidenav-overlay { |
This is not a solution imho. |
The solution works for my link items in the sidenav. But I also have a div user-view to show the users name and logout button This user view is clickable but not shown correctly. See image and code below.
|
Moving it out of the DIV works well, Ie if
I feel the documentation should be updated to make note of this or reference this. |
I had this problem and tried all of these to no avail. I realized that I had changed the z-index of to 1 for other reasons. Took it out, problem was solved! Maybe will help someone else. |
late 2018, problem still present and not documented! |
0.x releases are not supported anymore. 1.x is the new release. Please create a new issue and a codepen which reproduces the issue. |
The year is 2022: no gas, no fire wood, no complete Materialize documentation. |
@chrisAXZA me and @tomscholz were simple contributors and had not many rights. The problem is with the current maintainers @Dogfalo and @acburst who did not want to work with us to bring things forward. So some people (including me) created an actively maintained fork at https://github.com/materializecss/materialize, every contributor is very welcome there and longterm contributors get more rights there. We tried once more to get the original maintainers involved (see materializecss#263) or at least get the ok to forward / link to us but as you can see at materializecss#263 this was without success. |
Thanks for the response. Unfortunate indeed, perhaps in the long-run a dedicated webpage comprising additional document (ie. materialize-documentation.io), which to be frank is non-existent on materializecss.com (a trivial sidenav issue demands the inquiry to an impressive amount of stackoverflow and github-issue pages). Busy as they might be, also unfortunate that @Dogfalo and @acburst did not at least respond with regards to your inquiries. |
When using a Fixed Navbar and Mobile Collapse together, the overlay that normally covers the rest of the screen is now also covering the SideNav, which makes the links un-clickable. I tested it without the fixed navbar and there is no issue.
This was not a problem 0.97.7
Screenshot attached of the bug, as well as the code used (I replaced my code with the exact code from the documentation to rule out any possibility that my menu was the cause).
The text was updated successfully, but these errors were encountered: