Repository navigation
Accessible indicator that links open in a new window #48692
brianteeman
started this conversation in
1. Feature Evaluation
Replies: 4 comments 3 replies
|
Cool idea to use a plugin. Would it help if I tested it out? |
2 replies
|
Good idea and works in my test installation J6.2. As already mentioned, in the description, the css needs to be adapeted in core. |
0 replies
|
@brianteeman this change is accepted. Could you make the PR for the core? Then we can approve and test. |
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
resolves #48387 which correctly identifies that the way we indicate a link is an external link is purely visually with a css inserted icon and is not is not conveyed to assistive technologies but incorrectly only identified it as a problem with the
install from web- this problem is globalWe should
As a first draft proof of concept I have created a Joomla plugin https://github.com/brianteeman/external-link/
If you test it then you will see two icons - one before and one after - that is because the removal of the first css only icon should be done in the template not the plugin and if the plugin is accepted then i would correct the template css
The plugin adds an inline SVG icon at the end of each matching link, along with screen-reader-only text announcing that the link opens in a new tab or window. The icon is hidden from assistive technology with aria-hidden="true"; the announcement is translated through Joomla's JavaScript language-string support.
The final visible word and indicator are kept together where it is safe to do so, helping prevent the icon from wrapping onto a line by itself. Long final strings and links without a suitable visible word use a safe fallback.
The plugin is enabled in the administrator. An option allows it to be enabled on the frontend as well - its an option because a template may already do its own thing for this.
A link can be exluded by adding the
class="no-external-link-icon"- in core joomla we would want to add this class to the link in the mod_frontend moduleAll reactions