set focus for assignment muter dialogs

fixes CNVS-10555

test plan:
 In screenreader gradebook and gradebook2
  - open the assignment muter dialog
  - focus should be on the content of the dialog

Change-Id: Id4972ebef2f9a496b984bd0e799172844ffbb158
Reviewed-on: https://gerrit.instructure.com/29309
Reviewed-by: Matthew Irish <mirish@instructure.com>
Product-Review: Aaron Cannon <acannon@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
This commit is contained in:
Cameron Sutter 2014-01-24 16:24:46 -07:00
parent 2d5ca8af7c
commit 7ce30222bd
2 changed files with 26 additions and 23 deletions

View File

@ -27,6 +27,7 @@ define [
click: =>
@$dialog.disableWhileLoading $.ajaxJSON(@url, 'put', { status : true }, @afterUpdate)
}]
open: => setTimeout (=> @$dialog.find('#assignment_muter_content').focus()), 100
close: => @$dialog.remove()
resizable: false
width: 400

View File

@ -1,4 +1,5 @@
<div title="{{#t "mute_assignment"}}Mute Assignment{{/t}}">
<div id="assignment_muter_content" tabindex="-1">
<p>
{{#t "sure_you_want_to_mute"}}
Are you sure you want to mute this assignment? While this assignment
@ -22,4 +23,5 @@
notifications again by clicking the "Unmute Assignment" link.
{{/t}}
</p>
</div>
</div>