Skip to content

Commit

Permalink
feat: add accessibility link (#9)
Browse files Browse the repository at this point in the history
* feat: add accessibility link

* feat: add a test for the accessibility link

* refactor: lint
  • Loading branch information
asadali145 committed Jul 2, 2024
1 parent 03156ea commit 19e9138
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/components/Footer.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ class SiteFooter extends React.Component {
{this.renderLinkIfExists(process.env.PRIVACY_POLICY_URL, 'Privacy Policy')}
{this.renderLinkIfExists(process.env.HONOR_CODE_URL, 'Honor Code')}
{this.renderLinkIfExists(process.env.Contact, 'Contact')}
{this.renderLinkIfExists(process.env.ACCESSIBILITY_URL, 'Accessibility')}
{this.renderLinkIfExists(process.env.SUPPORT_CENTER_URL, process.env.SUPPORT_CENTER_TEXT || 'FAQ & Help')}
</ul>
</div>
Expand Down
21 changes: 21 additions & 0 deletions src/components/__snapshots__/Footer.test.jsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,13 @@ exports[`<Footer /> renders correctly renders with a language selector 1`] = `
Honor Code
</a>
</li>
<li>
<a
href="https://accessibility.mit.edu/"
>
Accessibility
</a>
</li>
<li>
<a
href="http://localhost:18000/about"
Expand Down Expand Up @@ -182,6 +189,13 @@ exports[`<Footer /> renders correctly renders without a language selector 1`] =
Honor Code
</a>
</li>
<li>
<a
href="https://accessibility.mit.edu/"
>
Accessibility
</a>
</li>
<li>
<a
href="http://localhost:18000/about"
Expand Down Expand Up @@ -262,6 +276,13 @@ exports[`<Footer /> renders correctly renders without a language selector in es
Honor Code
</a>
</li>
<li>
<a
href="https://accessibility.mit.edu/"
>
Accessibility
</a>
</li>
<li>
<a
href="http://localhost:18000/about"
Expand Down
1 change: 1 addition & 0 deletions src/setupTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,4 @@ process.env.SITE_URL = 'http://localhost:18000/';
process.env.LOGO_ALT_TEXT = 'alt text';
process.env.SHOW_LOGO = true;
process.env.SUPPORT_EMAIL = '[email protected]';
process.env.ACCESSIBILITY_URL = 'https://accessibility.mit.edu/';

0 comments on commit 19e9138

Please sign in to comment.