Skip to content

Commit

Permalink
Merge branch 'MDL-72674-master-fix' of github.com:sarjona/moodle
Browse files Browse the repository at this point in the history
  • Loading branch information
stronk7 committed Oct 8, 2021
2 parents 7ab2d7d + 3369faa commit d9d49fc
Showing 1 changed file with 6 additions and 11 deletions.
17 changes: 6 additions & 11 deletions admin/tool/componentlibrary/content/moodle/accessibility/links.md
Expand Up @@ -7,11 +7,11 @@ draft: false
---
## Links that open in a new window

Links that open in a new window or tab should indicate that they open in a new window or tab. This is especially helpful for screen reader users to let them know that clicking on the link will open a new window or tab. This helps eliminate confusion caused by changes in context such as opening a web page in a new window or tab.
Links that open in a new window or tab should indicate that they open in a new window or tab. This is especially helpful for screen reader users to let them know that clicking on the link will open a new window or tab. This helps eliminate confusion caused by changes in context such as opening a web page in a new window or tab.

There are several techniques that we can use when creating links that open in a new window.

### Using an image icon with alt text to indicate that the link opens in a new window
### Using an image icon with alt text to indicate that the link opens in a new window

{{< example >}}
<a href="https://moodle.org" target="_blank">
Expand All @@ -24,9 +24,9 @@ The core/userfeedback_footer_link is also good example for this one.
{{< mustache template="core/userfeedback_footer_link" >}}
{{< /mustache >}}

### Text that indicates that the link opens in a new window
### Text that indicates that the link opens in a new window

This may be the most straightforward way of indicating that links open in a new window. The potential downside of this approach is that it can be quite distracting, especially when the page has a lot of links that open in a new window.
This may be the most straightforward way of indicating that links open in a new window. The potential downside of this approach is that it can be quite distracting, especially when the page has a lot of links that open in a new window.

{{< example >}}
<a href="https://moodle.org" target="_blank">
Expand All @@ -36,7 +36,7 @@ This may be the most straightforward way of indicating that links open in a new

## Links to a file

A link to a file such as a PDF file or Word document will usually open the relevant application associated to the file type and will cause a change in context. It would be helpful to let users know when a link will open a file.
A link to a file such as a PDF file or Word document will usually open the relevant application associated to the file type and will cause a change in context. It would be helpful to let users know when a link will open a file.

### File type indicated in the link text
{{< example >}}
Expand All @@ -56,7 +56,7 @@ A link to a file such as a PDF file or Word document will usually open the relev

Similar to links that open in a new window, links that redirect to an external site may also have an indication that they lead to an external site to let users know that clicking on the link will take them away from Moodle.

The example link below opens in the same browser window and lets the user know that they will be redirected to Moodle.org, which is an external site.
The example link below opens in the same browser window and lets the user know that they will be redirected to Moodle.org, which is an external site.

{{< example >}}
<a href="https://moodle.org">
Expand All @@ -68,8 +68,3 @@ The example link below opens in the same browser window and lets the user know t

* [Understanding Success Criterion 3.2.5](https://www.w3.org/TR/2016/NOTE-UNDERSTANDING-WCAG20-20161007/consistent-behavior-no-extreme-changes-context.html)
* [Opening new windows and tabs from a link only when necessary](https://www.w3.org/TR/WCAG20-TECHS/G200.html)





0 comments on commit d9d49fc

Please sign in to comment.