diff --git a/layouts/partials/navigators/navbar.html b/layouts/partials/navigators/navbar.html
index 03f68c0..f936796 100644
--- a/layouts/partials/navigators/navbar.html
+++ b/layouts/partials/navigators/navbar.html
@@ -31,16 +31,7 @@
-
-
- {{ i18n "home" }}
-
+ {{ i18n "home" }}
{{ if $sections }}
{{ range sort $sections "section.weight" }}
@@ -50,15 +41,7 @@
{{ $sectionID = .section.id }}
{{ end }}
-
-
- {{ .section.name }}
-
+ {{ .section.name }}
{{ end }}
{{- end }}
diff --git a/static/assets/js/navbar.js b/static/assets/js/navbar.js
index c882cc6..3e44506 100644
--- a/static/assets/js/navbar.js
+++ b/static/assets/js/navbar.js
@@ -30,6 +30,15 @@
$('#logo').attr("src", invertedLogo);
}
});
+
+ // Creates a click handler to collapse the navigation when
+ // anchors in the mobile nav pop up are clicked
+ var navMain = $(".navbar-collapse");
+ navMain.on("click", "a", null, function (e) {
+ $('.navbar-collapse').collapse('hide');
+ });
});
})(jQuery);
+
+