Skip to content
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

Menubar Navigation Example: Make single page and improve implementation of APG coding practices #1612

Closed
wants to merge 59 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
465bebe
updated menubar navigation
jongund Oct 7, 2020
628ed1e
fixed init bug
jongund Oct 8, 2020
e0dca47
add home link
jongund Oct 8, 2020
0c39184
updated content generator
jongund Oct 8, 2020
0139a36
fixed current page bug
jongund Oct 8, 2020
5bacd89
added aria-owns
jongund Oct 8, 2020
e56eaf4
fixed tabindex bug
jongund Oct 8, 2020
a369fa4
added source code reference
jongund Oct 8, 2020
d77ff40
updated test file to identify tests that need to be updated
jongund Oct 8, 2020
652c7ac
Merge branch 'master' into update-menubar-nav
jongund Oct 20, 2020
08f990c
fixed merge conflicts
jongund Oct 26, 2020
9efae2e
initial implementation of menubar navigation
jongund Oct 26, 2020
20bd934
fixed initilization bug
jongund Oct 26, 2020
76d905c
updated page initialization and aria-current styling
jongund Oct 27, 2020
19f7d05
updated high contrast documentation
jongund Oct 27, 2020
cb78e5f
fixed linting error
jongund Oct 27, 2020
344fcae
fixed linting error
jongund Nov 9, 2020
63e68ad
fixed conflict and merged master
jongund Nov 11, 2020
60cec08
updated menubar navigation example
jongund Nov 11, 2020
88c9ba7
fixed focus bug
jongund Nov 11, 2020
6da5008
deleted commented out code
jongund Nov 11, 2020
3157a89
updated regression tests
jongund Nov 13, 2020
27d1958
updated regression tests
jongund Nov 13, 2020
0609261
fixed conflicts
jongund Nov 18, 2020
f56142e
fixing files that should not be updated
jongund Nov 20, 2020
843c157
fixing files that should not be updated
jongund Nov 20, 2020
ba1d2b0
fixing files that should not be updated
jongund Nov 20, 2020
51fcde6
fixed linting errors
jongund Nov 20, 2020
7668e55
updated aria-current styling
jongund Nov 22, 2020
2805a92
fixed some CSS selector issues
jongund Nov 23, 2020
4c04ee2
fixed some CSS selector issues
jongund Nov 23, 2020
9c6ad53
updated regression tests
jongund Nov 24, 2020
83095af
fixed typeof test
jongund Nov 24, 2020
9aa121c
updated menubar navigation regression tests
jongund Nov 25, 2020
0883938
fixed tag line text
jongund Dec 1, 2020
ae374af
fixed linting bugs
jongund Dec 2, 2020
7169f1f
added a title attribute to menuitems that containg the current page link
jongund Dec 2, 2020
a1f2446
fixed linting issue
jongund Dec 2, 2020
309ad51
Merge branch 'master' into update-menubar-nav
jongund Dec 4, 2020
92a7a7f
changed selectors for header and footer element styling
jongund Dec 4, 2020
446c892
fixed some issues related to coding practices and code pen compatibility
jongund Dec 4, 2020
e946195
fixed code pen issue
jongund Dec 4, 2020
f4ae426
deleted unused files
jongund Dec 14, 2020
f01a8d1
update test cases
jongund Dec 14, 2020
8ac18a0
updated regression tests
jongund Dec 14, 2020
f3d42bb
Merge branch 'master' into update-menubar-nav
jongund Dec 15, 2020
f563e18
updated documentation
jongund Dec 15, 2020
17e0335
Merge branch 'master' into update-menubar-nav
jongund Dec 15, 2020
9822487
updated regression tests
jongund Dec 15, 2020
76e95ca
finished regression tests
jongund Dec 16, 2020
42516f6
updated documentation
jongund Dec 16, 2020
4d1fbf1
updated accessibility documentation
jongund Jan 26, 2021
b4d954b
updated accessibility documentation
jongund Jan 26, 2021
5488c3f
fixing potential conflicts
jongund Jan 26, 2021
7787043
restored test util file
jongund Jan 26, 2021
a5ace11
fixing potential conflicts
jongund Jan 26, 2021
faca380
fixing potential conflicts
jongund Jan 26, 2021
9199504
updated example index file
jongund Jan 28, 2021
5d99d80
Merge branch 'master' into update-menubar-nav
jongund Jan 28, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 6 additions & 1 deletion examples/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ <h2 id="examples_by_role_label">Examples by Role</h2>
<td><code>banner</code></td>
<td>
<ul>
<li><a href="treeview/treeview-navigation.html">Navigation Treeview</a></li>
<li><a href="menubar/menubar-navigation.html">Navigation Menubar</a></li>
<li><a href="landmarks/banner.html">Banner Landmark</a></li>
</ul>
</td>
Expand Down Expand Up @@ -98,6 +98,7 @@ <h2 id="examples_by_role_label">Examples by Role</h2>
<td><code>contentinfo</code></td>
<td>
<ul>
<li><a href="menubar/menubar-navigation.html">Navigation Menubar</a></li>
<li><a href="treeview/treeview-navigation.html">Navigation Treeview</a></li>
<li><a href="landmarks/contentinfo.html">Contentinfo Landmark</a></li>
</ul>
Expand Down Expand Up @@ -222,6 +223,7 @@ <h2 id="examples_by_role_label">Examples by Role</h2>
<td><code>navigation</code></td>
<td>
<ul>
<li><a href="menubar/menubar-navigation.html">Navigation Menubar</a></li>
<li><a href="treeview/treeview-navigation.html">Navigation Treeview</a></li>
<li><a href="landmarks/navigation.html">Navigation Landmark</a></li>
</ul>
Expand Down Expand Up @@ -468,6 +470,7 @@ <h2 id="examples_by_props_label">Examples By Properties and States</h2>
<td>
<ul>
<li><a href="disclosure/disclosure-navigation.html">Disclosure for Navigation Menus</a></li>
<li><a href="menubar/menubar-navigation.html">Navigation Menubar</a></li>
<li><a href="treeview/treeview-navigation.html">Navigation Treeview</a></li>
</ul>
</td>
Expand Down Expand Up @@ -612,6 +615,7 @@ <h2 id="examples_by_props_label">Examples By Properties and States</h2>
<li><a href="menu-button/menu-button-actions-active-descendant.html">Actions Menu Button Using aria-activedescendant</a></li>
<li><a href="menu-button/menu-button-actions.html">Actions Menu Button Using element.focus()</a></li>
<li><a href="menu-button/menu-button-links.html">Navigation Menu Button</a></li>
<li><a href="menubar/menubar-navigation.html">Navigation Menubar</a></li>
<li><a href="radio/radio-activedescendant.html">Radio Group Using aria-activedescendant</a></li>
<li><a href="radio/radio.html">Radio Group Using Roving tabindex</a></li>
<li><a href="spinbutton/datepicker-spinbuttons.html">Date Picker Spin Button</a></li>
Expand Down Expand Up @@ -671,6 +675,7 @@ <h2 id="examples_by_props_label">Examples By Properties and States</h2>
</tr>
<tr>
<td><code>aria-owns</code></td>
<td><a href="menubar/menubar-navigation.html">Navigation Menubar</a></td>
<td><a href="treeview/treeview-navigation.html">Navigation Treeview</a></td>
</tr>
<tr>
Expand Down
118 changes: 97 additions & 21 deletions examples/menubar/css/menubar-navigation.css
Original file line number Diff line number Diff line change
@@ -1,13 +1,51 @@
.page header {
border: #005a9c solid 2px;
background: #005a9c;
color: white;
text-align: center;
}

.page header .title {
font-size: 2.5em;
font-weight: bold;
font-family: serif;
}

.page header .tagline {
font-style: italic;
}

.page .main {
padding-top: 1em;
padding-left: 5%;
padding-right: 5%;
padding-bottom: 5em;
border-left: 2px solid #eee;
border-right: 2px solid #eee;
}

.page footer {
border: #005a9c solid 2px;
background: #005a9c;
font-family: serif;
color: white;
font-style: italic;
padding-left: 1em;
}

.page nav {
margin: 0;
padding: 0;
border: 2px solid #eee;
}

.menubar-navigation {
margin: 0;
margin-top: 0.5em;
margin-bottom: 0.5em;
padding: 7px;
font-size: 110%;
list-style: none;
background-color: #eee;
border: #eee solid 1px;
border-radius: 5px;
}

.menubar-navigation li {
Expand All @@ -31,15 +69,20 @@
display: block;
width: 12em;
margin: 0;
padding: 6px;
padding-left: 9px;
background-color: #eee;
border: 0 solid #eee;
color: black;
}

.menubar-navigation [role="menuitem"],
.menubar-navigation [role="separator"] {
.menubar-navigation > li > [role="menuitem"] {
display: inline-block;
padding: 6px;
padding-bottom: 9px;
background-color: #eee;
border: 0 solid #eee;
color: black;
border-radius: 5px;
}

.menubar-navigation [role="menuitem"] svg {
Expand All @@ -65,18 +108,13 @@
transform: rotate(90deg) translate(5px, -5px);
}

.menubar-navigation > li > [role="menuitem"] {
display: inline-block;
}

.menubar-navigation [role="menu"] {
display: none;
position: absolute;
margin: 0;
padding: 0;
padding: 7px 4px;
border: 2px solid #034575;
border-radius: 5px;
background-color: #eee;
}

Expand All @@ -87,28 +125,66 @@

.menubar-navigation [role="separator"] {
padding-top: 3px;
background-image: url("../images/separator.svg");
background-image: url("data:image/svg+xml,%3C%3Fxml version='1.0' encoding='utf-8'%3F%3E%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cline x1='0' y1='6' x2='12' y2='6' style='stroke:black;stroke-width:1' /%3E%3C/svg%3E%0A");
background-position: center;
background-repeat: repeat-x;
}
spectranaut marked this conversation as resolved.
Show resolved Hide resolved

/* aria-current styling */

.menubar-navigation [role="menu"] [role="menuitem"].aria-current-path,
.menubar-navigation [role="menu"] [role="menuitem"][aria-current] {
padding-left: 4px;
border-left: 5px solid #034575;
background-color: #ccc;
}

.menubar-navigation > li > [role="menuitem"][aria-current],
.menubar-navigation > li > [role="menuitem"].aria-current-path {
padding-bottom: 4px;
border-bottom: 5px solid #034575;
background-color: #ccc;
}

/* focus styling */

.menubar-navigation.focus {
padding: 6px;
border: #034575 solid 2px;
}

.menubar-navigation [role="menuitem"][aria-expanded="true"],
.menubar-navigation [role="menuitem"]:focus,
.menubar-navigation [role="menuitem"]:hover {
background: #034575;
color: #fff;
.menubar-navigation [role="menu"] [aria-expanded="true"],
.menubar-navigation [role="menu"] [role="menuitem"]:focus,
.menubar-navigation [role="menu"] [role="menuitem"]:hover {
outline: none;
padding: 4px;
padding-left: 7px;
border: 2px solid #034575;
}

.menubar-navigation [role="menu"] [aria-expanded="true"].aria-current-path,
.menubar-navigation [role="menu"] [role="menuitem"].aria-current-path:focus,
.menubar-navigation [role="menu"] [role="menuitem"].aria-current-path:hover,
.menubar-navigation [role="menu"] [role="menuitem"][aria-current]:focus,
.menubar-navigation [role="menu"] [role="menuitem"][aria-current]:hover {
padding-left: 4px;
border-left: 5px solid #034575;
}

.menubar-navigation > li > [aria-expanded="true"],
.menubar-navigation > li > [role="menuitem"]:focus,
.menubar-navigation > li > [role="menuitem"]:hover {
outline: none;
padding: 4px;
padding-bottom: 7px;
border: 2px solid #034575;
}

.menubar-navigation [role="menuitem"]:focus,
.menubar-navigation [role="menuitem"]:hover {
padding: 2px;
border: 4px solid #034575;
.menubar-navigation > li > [aria-expanded="true"].aria-current-path,
.menubar-navigation > li > [role="menuitem"].aria-current-path:focus,
.menubar-navigation > li > [role="menuitem"].aria-current-path:hover,
.menubar-navigation > li > [role="menuitem"][aria-current]:focus,
.menubar-navigation > li > [role="menuitem"][aria-current]:hover {
padding-bottom: 4px;
border-bottom: 5px solid #034575;
}
4 changes: 4 additions & 0 deletions examples/menubar/images/aria-current.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.