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 authored and blarghmatey committed Dec 7, 2023
1 parent d2e38ef commit 0b167c5
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 @@ -181,6 +188,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 @@ -261,6 +275,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 @@ -36,3 +36,4 @@ process.env.SITE_URL = 'http://localhost:18000/';
process.env.LOGO_ALT_TEXT = 'alt text';
process.env.SHOW_LOGO = true;
process.env.SUPPORT_EMAIL = 'webmaster@email.com';
process.env.ACCESSIBILITY_URL = 'https://accessibility.mit.edu/';

0 comments on commit 0b167c5

Please sign in to comment.