Skip to content
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

Improve alt-text for ORCiD icon #494

Closed
mitchelloharawild opened this issue Sep 28, 2023 · 3 comments
Closed

Improve alt-text for ORCiD icon #494

mitchelloharawild opened this issue Sep 28, 2023 · 3 comments
Assignees
Labels
feature a feature request or enhancement next to consider for next release

Comments

@mitchelloharawild
Copy link
Contributor

From R Journal: rjournal/rjtools#86

Would it be possible to bring in additional information into the alt-text to improve the screen-reader experience? Currently the alt-text doesn't identify who's ORCiD is who's.

// add orcid ids
$('.authors-affiliations').find('.author').each(function(i, el) {
var orcid_id = front_matter.authors[i].orcidID;
if (orcid_id) {
var a = $('<a></a>');
a.attr('href', 'https://orcid.org/' + orcid_id);
var img = $('<img></img>');
img.addClass('orcid-id');
img.attr('alt', 'ORCID ID');
img.attr('src','data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA2ZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9t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o8T0QSxkjSwORsCAuDQCD+QILmD1A9kECEZgxDaEZhICIzGcIyEyOl2RkgwAAhkmC+eAm0TAAAAABJRU5ErkJggg==');
a.append(img);
$(this).append(a);
}
});

@cderv
Copy link
Collaborator

cderv commented Sep 28, 2023

This seems to be an easy change. How do you suggest to do this ?

New YAML field or reuse some existing informations like the author name in alt text ?

@cderv cderv added next to consider for next release feature a feature request or enhancement labels Sep 28, 2023
@mitchelloharawild
Copy link
Contributor Author

I think re-using existing information is best, then we have accessibility by default.

@cderv cderv closed this as completed in f8c1a54 Sep 29, 2023
@cderv cderv self-assigned this Sep 29, 2023
@mitchelloharawild
Copy link
Contributor Author

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature a feature request or enhancement next to consider for next release
Projects
Archived in project
Development

No branches or pull requests

2 participants