@@ -25,22 +25,24 @@ nav.nav-bar, nav.nav-block {
2525 }
2626}
2727
28+ // Styles to add background colors into navigation bars. Used on dropdowns, accordions, and hamburger menus, among others
2829
29- .nav-filled {
30- ul {
31- li {
32- a {
33- background : $light-background ;
34- color : $primary-color ;
30+ .nav-filled {
31+ ul {
32+ li {
33+ a {
34+ background : $light-background ;
35+ color : $primary-color ;
3536
36- & :hover {
37- background : darken ($tertiary-color , 5% );
37+ & :hover {
38+ background : darken ($tertiary-color , 5% );
39+ }
3840 }
3941 }
4042 }
4143 }
42- }
4344
45+ // The basic styles for nav bars on tablet and desktop-sized screens
4446
4547@media (min-width : 50rem ) {
4648 nav .nav-bar {
@@ -65,6 +67,8 @@ nav.nav-bar, nav.nav-block {
6567 }
6668}
6769
70+ // Styles for aligning navigation links to the left or right
71+
6872nav .left , nav .right {
6973
7074 ul {
@@ -86,7 +90,6 @@ nav.left, nav.right {
8690}
8791
8892
89-
9093nav .right {
9194
9295 ul {
@@ -100,8 +103,8 @@ nav.right {
100103}
101104
102105
103-
104106// Simple Vertical Navigation Block
107+ // Just add this to any nav bar to make it vertical.
105108
106109nav .nav-block {
107110
@@ -118,10 +121,11 @@ nav.nav-block {
118121}
119122
120123
121-
122124// The Dropdown Navigation Bar
123125
124- // First, let's hide the child lists from view.
126+ // This works with no JS, using a checkbox to implement the show/hide on click functionality
127+
128+ // First, let's hide the child lists from view
125129
126130nav .dropdown {
127131 ul li ul {
@@ -142,7 +146,7 @@ nav.dropdown {
142146 flex : 1 ;
143147 }
144148
145- // Hide the actual checkbox. People will click the label to reveal the dropdown
149+ // Hide the actual checkbox - People will click the label to reveal the dropdown
146150
147151 input [type = checkbox ] {
148152 display : none ;
@@ -170,7 +174,7 @@ nav.dropdown {
170174 }
171175 }
172176
173- // Some styles specifically for the vertical navigation block
177+ // Some styles specifically for the using the vertical navigation block with dropdowns
174178
175179 & .nav-block {
176180 ul li ul {
@@ -179,6 +183,7 @@ nav.dropdown {
179183 }
180184}
181185
186+ // And now, the desktop / tablet version
182187
183188@media (min-width : 50rem ) {
184189 nav .dropdown {
@@ -215,6 +220,8 @@ nav.dropdown {
215220
216221// The Centered Navigation Bar
217222
223+ // Simply put, this aligns all the links to the middle
224+
218225nav .centered {
219226 ul {
220227 display : flex ;
@@ -246,6 +253,8 @@ nav.centered {
246253
247254// Hamburger Navigation
248255
256+ // Works on the same principle as the drop-down menu, requires a checkbox
257+
249258nav .hamburger {
250259
251260 input [type = checkbox ] {
@@ -319,6 +328,8 @@ nav.breadcrumb {
319328
320329// Accordion Navigation
321330
331+ // Drop-down and hamburger menus on steroids
332+
322333nav .accordion {
323334
324335 input [type = checkbox ] {
0 commit comments