Skip to content

Commit

Permalink
feat: Nav landmark accessibility
Browse files Browse the repository at this point in the history
  • Loading branch information
kriscooke committed Aug 20, 2020
1 parent 5a5618c commit 429d1c1
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/components/Layout/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const HeaderLayout = ({isLoggedIn = false, isRegistered = false, children}) => {
return (
<header>
<div className="nav-header">
<nav>
<nav aria-label="Main">
<div className="header-left">
<Link href="/">
<a>
Expand Down
2 changes: 1 addition & 1 deletion app/components/Layout/Subheader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const Subheader = () => {

return (
<div>
<nav className="navigation-main" id="navbar">
<nav className="navigation-main" id="navbar" aria-label="Secondary">
<div className="container">
<ul>
<li className={asPath === DASHBOARD_PATH ? 'active' : ''}>
Expand Down
6 changes: 6 additions & 0 deletions app/tests/integration/__snapshots__/Storyshots.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Array [
className="jsx-2584110530 nav-header"
>
<nav
aria-label="Main"
className="jsx-2584110530"
>
<div
Expand Down Expand Up @@ -529,6 +530,7 @@ Array [
className="jsx-2584110530 nav-header"
>
<nav
aria-label="Main"
className="jsx-2584110530"
>
<div
Expand Down Expand Up @@ -1022,6 +1024,7 @@ Array [
className="jsx-2584110530 nav-header"
>
<nav
aria-label="Main"
className="jsx-2584110530"
>
<div
Expand Down Expand Up @@ -1133,6 +1136,7 @@ Array [
</div>
<div>
<nav
aria-label="Secondary"
className="jsx-2326483044 navigation-main"
id="navbar"
>
Expand Down Expand Up @@ -1687,6 +1691,7 @@ Array [
className="jsx-2584110530 nav-header"
>
<nav
aria-label="Main"
className="jsx-2584110530"
>
<div
Expand Down Expand Up @@ -2029,6 +2034,7 @@ Array [
className="jsx-2584110530 nav-header"
>
<nav
aria-label="Main"
className="jsx-2584110530"
>
<div
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ exports[`It matches the last accepted Snapshot 1`] = `
className="jsx-2584110530 nav-header"
>
<nav
aria-label="Main"
className="jsx-2584110530"
>
<div
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
exports[`The Subheader matches the last accepted Snapshot 1`] = `
<div>
<nav
aria-label="Secondary"
class="jsx-2326483044 navigation-main"
id="navbar"
>
Expand Down

0 comments on commit 429d1c1

Please sign in to comment.