Add Expand/Collapse screenreader message on Modules
Fixes CNVS-20464 Test Plan: - Use NVDA on Firefox and navigate to Modules page - Expand and collapse a module - You should expect to hear "Exapnded" and "Collaped" from the screenreader Change-Id: I29778f8c26d1d9e54c1e4ef40c96dec107521232 Reviewed-on: https://gerrit.instructure.com/57615 Tested-by: Jenkins Reviewed-by: Sterling Cobb <sterling@instructure.com> QA-Review: Adam Stone <astone@instructure.com> Product-Review: Brock Cooper <bcooper@instructure.com>
This commit is contained in:
parent
1bbcf36b28
commit
4dd1666cc9
|
@ -45,7 +45,8 @@ define([
|
|||
'jquery.templateData' /* fillTemplateData, getTemplateData */,
|
||||
'vendor/date' /* Date.parse */,
|
||||
'vendor/jquery.scrollTo' /* /\.scrollTo/ */,
|
||||
'jqueryui/sortable' /* /\.sortable/ */
|
||||
'jqueryui/sortable' /* /\.sortable/ */,
|
||||
'compiled/jquery.rails_flash_notifications'
|
||||
], function(_, ModuleFile, PublishCloud, React, PublishableModuleItem, PublishIconView, INST, I18n, $, ContextModulesView, RelockModulesDialog, vddTooltip, vddTooltipView, Publishable, PublishButtonView, htmlEscape) {
|
||||
|
||||
// TODO: AMD don't export global, use as module
|
||||
|
@ -1598,12 +1599,14 @@ define([
|
|||
$module.toggleClass('collapsed_module', false);
|
||||
// Makes sure the resulting item has focus.
|
||||
$module.find(".collapse_module_link").focus();
|
||||
$.screenReaderFlashMessage(I18n.t('Expanded'));
|
||||
|
||||
} else {
|
||||
$module.find(".footer .manage_module").css('display', ''); //'none');
|
||||
$module.toggleClass('collapsed_module', true);
|
||||
// Makes sure the resulting item has focus.
|
||||
$module.find(".expand_module_link").focus();
|
||||
$.screenReaderFlashMessage(I18n.t('Collapsed'));
|
||||
}
|
||||
if(expandCallback && $.isFunction(expandCallback)) {
|
||||
expandCallback();
|
||||
|
|
Loading…
Reference in New Issue