Skip to content

USWDS - Links: External link labels #5166

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

Merged
merged 16 commits into from
May 10, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add noreferrer to all external links
  • Loading branch information
James Mejia committed Apr 10, 2023
commit fae1ed3349d20fd92af2cdb3a0ccd56c0410e41d
4 changes: 2 additions & 2 deletions packages/usa-link/src/usa-link.twig
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<p>This is <a class="usa-link usa-color-text-visited" href="javascript:void(0);">a visited link</a>.</p>

<p>
This is a link that opens in <em>current</em> tab and goes to an <a class="usa-link usa-link--external" href="https://i.giphy.com/media/WPzQF6ruiIIVzHNlwX/source.gif">external website</a>.
This is a link that opens in <em>current</em> tab and goes to an <a class="usa-link usa-link--external" rel="noreferrer" href="https://i.giphy.com/media/WPzQF6ruiIIVzHNlwX/source.gif">external website</a>.
</p>

<p>
Expand All @@ -12,5 +12,5 @@

<div class="usa-dark-background padding-1 display-inline-block">
<p>This is <a class="usa-link" href="javascript:void(0);">a text link on a dark background</a>.</p>
<p><a class="usa-link usa-link--alt usa-link--external" href="https://i.giphy.com/media/WPzQF6ruiIIVzHNlwX/source.gif">This</a> is an alternate external text link on a dark background.</p>
<p><a class="usa-link usa-link--alt usa-link--external" rel="noreferrer" href="https://i.giphy.com/media/WPzQF6ruiIIVzHNlwX/source.gif">This</a> is an alternate external text link on a dark background.</p>
</div>