make page views csv link text phrase more informative

Links are more useful when they make sense out of context.
We want to avoid non-informative link phrases regardless
if the context seems clear or we're under a header that
was previously read off by the screen reader.

fixes FOO-2017

test plan:
 1. Navigate to a user's profile page in Canvas
 2. Tab to csv link underneath Page Views header
 3. With VO on, verify the label now reads:
    "link, Download Page Views CSV", instead of:
    "link, csv"

Change-Id: Ife134e636fbeecac0841f63ff13a1884f68b2444
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/266318
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Michael Ziwisky <mziwisky@instructure.com>
QA-Review: Michael Ziwisky <mziwisky@instructure.com>
Product-Review: August Thornton <august@instructure.com>
This commit is contained in:
August Thornton 2021-06-03 15:34:49 -06:00
parent 0094448180
commit daa9c594dd
1 changed files with 6 additions and 1 deletions

View File

@ -33,7 +33,12 @@
<th><%= t('headers.time', "Time") %></th>
<th>
<div style="float:<%= direction('right') %>; margin-<%= direction('right') %>: 4px">
<%= link_to("csv", user_page_views_path(@user, :format => :csv), :class => 'icon-ms-excel', :id => 'page_views_csv_link') %>
<%= link_to(t('page views csv'),
user_page_views_path(@user, :format => :csv),
class: 'icon-ms-excel',
id: 'page_views_csv_link',
'aria-label' => t('Download Page Views CSV'))
%>
</div>
<%= t('headers.user_agent', "User Agent") %>
</th>