Skip to content
This repository was archived by the owner on Oct 1, 2020. It is now read-only.

Commit 8a09010

Browse files
author
Shashank Kumar
committed
Handling navbar collapse
JS function is added which will collapse navbar whenever any navlink is clicked.
1 parent 3cdf72f commit 8a09010

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

Diff for: index.html

+1
Original file line numberDiff line numberDiff line change
@@ -851,6 +851,7 @@ <h3 class="g-font-size-18--xs g-color--white">CybrosX</h3>
851851
<script type="text/javascript" src="js/components/parallax.min.js"></script>
852852
<script type="text/javascript" src="js/components/google-map.min.js"></script>
853853
<script type="text/javascript" src="js/components/wow.min.js"></script>
854+
<script type="text/javascript" src="js/components/nav.js"></script>
854855
<!--========== END JAVASCRIPTS ==========-->
855856

856857
</body>

Diff for: js/components/nav.js

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
// Handling navbars collapse
2+
3+
$('.s-header__nav-menu-item').click(function() {
4+
console.log('clicked');
5+
$('.s-header-bg-overlay').removeClass('-is-open');
6+
$('.navbar-fixed-top').removeClass('-is-open');
7+
$('.s-header__trigger').removeClass('-is-active');
8+
});

0 commit comments

Comments
 (0)