codyhouse / auto-hiding-navigation Goto Github PK
View Code? Open in Web Editor NEWA simple navigation that auto-hides when the user scrolls down, and becomes visible when the user scrolls up.
A simple navigation that auto-hides when the user scrolls down, and becomes visible when the user scrolls up.
Hi CodyHouse team,
How to make menu items scrollable if I have many menu items? Please help me
Hello!!
I tried to create some submenu in fixed subnav but when it gets collapsed for mobiles, the submenu button lost its css. I tried to solve it thousands of times but don't know how.
Iis it possible to add an example of a submenu in the fixed navbar?
Thank you in advance!!
Dear team,
thanks for bringing up this tool !
I come to ask whether it is compatible with bootstrap or not ? Indeed, I try to manage the proposed class system as follows :
<header class="cd-auto-hide-header">
<nav id="global-nav" class="navbar navbar-expand navbar-light fixed-top bg-light d-none d-sm-block">
<!-- the container-fluid allows to work with flex -->
<div class="container-fluid">
<a class="nav-brand float-left" href="dashboard.php"><img width="150px" src="./img/logo.png" alt="logo"/></a>
<ul class="navbar-nav mx-auto flex-nowrap flex-row">
<li class="nav-item">
<a class="nav-link" href="#">Nav item</a>
</li>
</ul>
</div>
<nav>
</header>
<main class="cd-main-content">
---content of page
</main>
With adding the js file and the css styles from the tutorial https://codyhouse.co/gem/auto-hiding-navigation;
but it does not work; as a result I just get my nav permanently hidden.
thanks...
If you scroll down (with mousewheel) the chrome will directly disappear the navigation. The Firefox working not the same way, why ever.
Another idea/suggestion is to get the navigation shown if you are in the upper area of the page. This was not working for me under FF. So I changed the function "checkSimpleNavigation" a little bit in the first if-query:
//there's no secondary nav or secondary nav is below primary nav
if (previousTop - currentTop > scrollDelta || currentTop < scrollOffset) {
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.