]> git.mjollnir.org Git - moodle.git/commitdiff
Fixes MDL-11695, Skip block links inaccessible for many keyboard-only users
authornfreear <nfreear>
Thu, 11 Oct 2007 16:35:20 +0000 (16:35 +0000)
committernfreear <nfreear>
Thu, 11 Oct 2007 16:35:20 +0000 (16:35 +0000)
lib/weblib.php
theme/standard/styles_layout.css

index 921db0fe68e9a569548a06397a36dbe94eea7e31..5d428369db7e586197d62c6299c6863f4752d388 100644 (file)
@@ -5926,15 +5926,13 @@ function print_side_block($heading='', $content='', $list=NULL, $icons=NULL, $fo
     else {
         $skip_text = get_string('skipa', 'access', strip_tags($title));
     }
-    $skip_link = '<a href="#sb-'.$block_id.'" class="skip-block" title="'.$skip_text.'">'."\n".get_accesshide($skip_text)."\n".'</a>';
+    $skip_link = '<a href="#sb-'.$block_id.'" class="skip-block">'.$skip_text.'</a>';
     $skip_dest = '<span id="sb-'.$block_id.'" class="skip-block-to"></span>';
 
     if (! empty($heading)) {
-        $heading = $skip_link . $heading;
-    }
-    /*else { //ELSE: I think a single link on a page, "Skip block 4" is too confusing - don't print.
         echo $skip_link;
-    }*/
+    }
+    //ELSE: a single link on a page "Skip block 4" is too confusing - ignore.
 
     print_side_block_start($heading, $attributes);
 
@@ -6593,4 +6591,4 @@ function fix_align_rtl($align) {
 
 
 // vim:autoindent:expandtab:shiftwidth=4:tabstop=4:tw=140:
-?>
+?>
\ No newline at end of file
index 850cf1de55c7ad4f3448e49ffe071c1734bd1318..5229764454bb32bf9087d67c9f9ecd3991a3b3f3 100644 (file)
@@ -1178,14 +1178,15 @@ body#admin-modules table.generaltable td.c0
  *** Blocks
  ***/
 
-/*Accessibility: Skip block link, for screen reader users. */
-a.skip-block, .skip-block {
-  display:block;
-  width:2em;
-  height:1px;
+/*Accessibility: Skip block link, for keyboard-only users. */
+a.skip-block {
+  position: absolute;
+  top: -1000em;
+  font-size: 0.85em;
 }
-.sideblock .skip-block {
-  height:4px;
+a.skip-block:focus, a.skip-block:active {
+  position: static;
+  display: block;
 }
 .skip-block-to {
   display: block;
@@ -4269,4 +4270,4 @@ wikiadminactions {
   background: #eee;
   border: 1px dashed #ddd;
   padding: 3px;
-}
+}
\ No newline at end of file