From 45c1f28d5f79f065c5f8cfd46f982f2a9dc7ef28 Mon Sep 17 00:00:00 2001 From: Chris Rodriguez Date: Mon, 6 Jul 2015 12:04:13 -0400 Subject: [PATCH 1/2] Fixing aria values and contrast for accessibility --- .../sass/course/modules/_calculator.scss | 41 ++++++++++++++++--- .../calculator/toggle_calculator.html | 2 +- 2 files changed, 37 insertions(+), 6 deletions(-) diff --git a/lms/static/sass/course/modules/_calculator.scss b/lms/static/sass/course/modules/_calculator.scss index 24d6aff666..5da357037a 100644 --- a/lms/static/sass/course/modules/_calculator.scss +++ b/lms/static/sass/course/modules/_calculator.scss @@ -37,14 +37,20 @@ div.calc-main { background-color: $black; top: -36px; } + + .utility-control-label { + background: $black; + color: $white; + } } div#calculator_wrapper { - background: $black; clear: both; - max-height: 90px; position: relative; top: -36px; + max-height: 90px; + background: $black; + color: $white; // UI: input help table .calculator-input-help-table { @@ -62,6 +68,12 @@ div.calc-main { @include box-sizing(border-box); padding: lh(); + label.sr { + // including the label here in case other .sr values are added + // we want to limit this 'white' only to the label + color: $white; + } + button#calculator_button { background: #111; border: 1px solid $black; @@ -82,6 +94,13 @@ div.calc-main { &:hover, &:focus { color: #333; } + + span.sr { + // including the element here in case other .sr values are added + // we want to limit this 'white' only to the span + background: $black; + color: $white; + } } input#calculator_output { @@ -125,19 +144,31 @@ div.calc-main { right: 0; top: 0; + #hint-instructions { + color: $white; + } + #calculator_hint { - background: url("../images/info-icon.png") center center no-repeat; - height: 35px; @include hide-text; - width: 35px; display: block; + height: 35px; + width: 35px; border: none; + background: url("../images/info-icon.png") center center no-repeat; + color: $white; &:focus { outline: 5px auto #5b9dd9; box-shadow: none; border: none; } + + span.sr { + // including the element here in case other .sr values are added + // we want to limit this 'white' only to the span + background: $black; + color: $white; + } } .help { diff --git a/lms/templates/calculator/toggle_calculator.html b/lms/templates/calculator/toggle_calculator.html index de00734150..97d034c496 100644 --- a/lms/templates/calculator/toggle_calculator.html +++ b/lms/templates/calculator/toggle_calculator.html @@ -17,7 +17,7 @@ from django.core.urlresolvers import reverse

${_('Use the arrow keys to navigate the tips or use the tab key to return to the calculator')}

- +
- - + +