Commit 370eb970 by Chris Rodriguez

Accessibility issues addressing UX-1573

Conflicts:
	common/lib/xmodule/xmodule/css/sequence/display.scss
parent 4ee99f19
...@@ -106,10 +106,6 @@ nav.sequence-nav { ...@@ -106,10 +106,6 @@ nav.sequence-nav {
padding: 0; padding: 0;
position: relative; position: relative;
/* &:focus {
outline: 0;
}
*/
&:hover, &:focus { &:hover, &:focus {
background-color: $white; background-color: $white;
background-repeat: no-repeat; background-repeat: no-repeat;
...@@ -120,17 +116,6 @@ nav.sequence-nav { ...@@ -120,17 +116,6 @@ nav.sequence-nav {
@extend %ui-depth1; @extend %ui-depth1;
background-color: $white; background-color: $white;
// &:after {
// content: '▲';
// position: absolute;
// top: 28px;
// left: 50%;
// z-index: 9999;
// margin-left: -5px;
// font-size: 12px;
// color: #aaa;
// }
&:hover, &:focus { &:hover, &:focus {
background-color: $white; background-color: $white;
background-repeat: no-repeat; background-repeat: no-repeat;
...@@ -213,7 +198,6 @@ nav.sequence-nav { ...@@ -213,7 +198,6 @@ nav.sequence-nav {
visibility: hidden; visibility: hidden;
pointer-events: none; pointer-events: none;
&:empty { &:empty {
background: none; background: none;
...@@ -280,10 +264,6 @@ nav.sequence-nav { ...@@ -280,10 +264,6 @@ nav.sequence-nav {
overflow: hidden; overflow: hidden;
@include transition(all .2s $ease-in-out-quad 0s); @include transition(all .2s $ease-in-out-quad 0s);
/* &:focus {
outline: 0;
}
*/
&:hover, &:focus { &:hover, &:focus {
opacity: 0.5; opacity: 0.5;
} }
...@@ -382,11 +362,7 @@ nav.sequence-bottom { ...@@ -382,11 +362,7 @@ nav.sequence-bottom {
&.disabled { &.disabled {
opacity: 0.4; opacity: 0.4;
} }
/* &:focus {
outline: 0;
} }
*/ }
} }
&.prev { &.prev {
...@@ -429,15 +405,10 @@ nav.sequence-bottom { ...@@ -429,15 +405,10 @@ nav.sequence-bottom {
} }
} }
.xmodule_VerticalModule div.vert-mod > div ul.sequence-nav-buttons { #seq_content {
list-style: none !important;
}
.xmodule_SequenceModule nav.sequence-bottom ul li.next a,
.xmodule_SequenceModule nav.sequence-bottom ul li.prev a {
/* &:focus { &:focus,
outline: 0; &:active {
outline: none;
} }
*/
} }
...@@ -4,6 +4,7 @@ class @Sequence ...@@ -4,6 +4,7 @@ class @Sequence
@el = $(element).find('.sequence') @el = $(element).find('.sequence')
@contents = @$('.seq_contents') @contents = @$('.seq_contents')
@content_container = @$('#seq_content') @content_container = @$('#seq_content')
@sr_container = @$('#sr-is-focusable')
@num_contents = @contents.length @num_contents = @contents.length
@id = @el.data('id') @id = @el.data('id')
@ajaxUrl = @el.data('ajax-url') @ajaxUrl = @el.data('ajax-url')
...@@ -114,6 +115,8 @@ class @Sequence ...@@ -114,6 +115,8 @@ class @Sequence
sequence_links = @content_container.find('a.seqnav') sequence_links = @content_container.find('a.seqnav')
sequence_links.click @goto sequence_links.click @goto
@sr_container.focus();
@$("a.active").blur() @$("a.active").blur()
goto: (event) => goto: (event) =>
......
<%! from django.utils.translation import ugettext as _ %> <%! from django.utils.translation import ugettext as _ %>
<div id="sequence_${element_id}" class="sequence" data-id="${item_id}" data-position="${position}" data-ajax-url="${ajax_url}" > <div id="sequence_${element_id}" class="sequence" data-id="${item_id}" data-position="${position}" data-ajax-url="${ajax_url}" >
<nav class="sequence-nav"> <nav class="sequence-nav" aria-label="${_('Unit')}" >
<ul class="sequence-nav-buttons"> <ul class="sequence-nav-buttons">
<li class="prev"><a role="button" href="#">${_('Previous')}</a></li> <li class="prev"><a role="button" href="#">${_('Previous')}</a></li>
</ul> </ul>
<div class="sequence-list-wrapper"> <div class="sequence-list-wrapper">
<ol role="tablist" aria-label="${_('Section Navigation')}" id="sequence-list"> <ol role="tablist" id="sequence-list">
% for idx, item in enumerate(items): % for idx, item in enumerate(items):
## TODO (vshnayder): add item.progress_detail either to the title or somewhere else. ## TODO (vshnayder): add item.progress_detail either to the title or somewhere else.
## Make sure it gets updated after ajax calls. ## Make sure it gets updated after ajax calls.
...@@ -44,10 +44,11 @@ ...@@ -44,10 +44,11 @@
${item['content'] | h} ${item['content'] | h}
</div> </div>
% endfor % endfor
<div id="seq_content" role="tabpanel"></div> <div id="sr-is-focusable" tabindex="-1"></div>
<div id="seq_content"></div>
<nav class="sequence-bottom"> <nav class="sequence-bottom" aria-label="${_('Section')}">
<ul aria-label="${_('Section Navigation')}" class="sequence-nav-buttons"> <ul class="sequence-nav-buttons">
<li class="prev"><a role="button" href="#">${_("Previous")}</a></li> <li class="prev"><a role="button" href="#">${_("Previous")}</a></li>
<li class="next"><a role="button" href="#">${_("Next")}</a></li> <li class="next"><a role="button" href="#">${_("Next")}</a></li>
</ul> </ul>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment